-# Set Partial Parameters Defaults
- job = nil unless local_assigns[:job]
- confirm = false unless local_assigns[:confirm]

- if job
  #job_details
    -# display application confirmation (if applicable)
    - if job.id == session[:applied_id]
      .apply-status-ok
        Congratulations, your application has been sent! Best of luck to you!
  
    -# display job outdated warning if applicable
    - if job.created_at < 40.days.ago
      .old-ad
        This job ad has been posted over 40 days ago...
  
    -# show applicants
    - unless confirm
      .applied-to-job
        = job.job_applicants.size
        %p
          - if job.job_applicants.size != 1
            applicants
          - else
            applicant
  
    -# show job title
    %h2
      = job_type_image(job.job_type)
      =h job.title
  
    -# show job location
    %p
      %span.fading at
      - unless job.url.blank? or job.url == "http://"
        = link_to h(job.company), job.url
      - else
        %strong=h job.company
    
      - if job.located_at == "Anywhere"
        %strong== (#{h(job.located_at)})
      - else
        %span.fading in
        %strong=h job.located_at
    
    -# show job description
    .job-description
      = job.description_html
    = br
    
    -# show job apply form
    - if !confirm and job.apply_online?
      #apply_online_now= link_to "&raquo; Apply now", "#"
      #apply_online{hide_unless(@job_applicant)}
        = partial "jobs/parts/apply_form", :job => job, :job_applicant => @job_applicant
    
    #job_bottom
      #job_post_utils
        = link_to "&laquo; go back to the homepage", root_url
        = br
        Is this job ad fake?
        = link_to "Report it!", "#", :onclick => "Jobber.ReportSpam('/jobs/#{job.id}/report_spam/', #{job.id}); return false;"
        = nbsp*2
        %span#report_spam_response
        = br
      #number_views
        Published at: 
        %strong= job.created_at.to_s(:post_listing_date)
        = br
        Viewed:
        %strong= pluralize(job.view_count, "time")
      = clear
        